﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ColumnSet.aspx.cs" Inherits="CNVP.JShop.Web.Admin.CommonWindows.ColumnSet" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <link href="../CSS/Edit.css" rel="stylesheet" type="text/css" />
    <script src="../../Scripts/jquery.js" type="text/javascript"></script>
    <script src="../../Scripts/Common.js" type="text/javascript"></script>
    <script type ="text/javascript">
        $(function () {
            $("#ButtonAddSubMenu").click(function () {
                var $txtID = $("#txtID");
                var $txtDepth = $("#txtDepth");
                if ($txtID.val() == "" && $txtDepth.val() == "") {
                    alert("请选择左边节点！");
                    return false;
                }
                return true;
            });
            $("#btUp").click(function () {
                var $txtDepth = $("#txtDepth");
                if ($txtDepth.val() == "") {
                    alert("请点击左边添加节点按钮！");
                    return false;
                }
                var $txtMenuName = $("#txtMenuName");
                var $txtMenuUrl = $("#txtMenuUrl");
                var $ddlProductTypeID = $("#ddlProductTypeID");
                var $txtWeight = $("#txtWeight");
                if ($txtMenuName.val() == "") {
                    alert("请输入名称！");
                    $txtMenuName.focus();
                    return false;
                }
                if ($ddlProductTypeID.val() == "0") {
                    alert("请选择商品类型！");
                    $ddlProductTypeID.focus();
                    return false;
                }
                if ($txtWeight.val() == "") {
                    alert("请输入排序！");
                    $txtWeight.focus();
                    return false;
                }
                else if (!IsInteger($txtWeight.val())) {
                    alert("排序格式不正确！");
                    $txtWeight.focus();
                    return false;
                }
                return true;
            });
        });
    </script>
</head>
<body>
    <form id="form1" runat="server">
        <table class="division">
                        <tr>
                            <td style="width: 150px;" valign="top">
                             <div class="EditBtnMenu">
                                <asp:Button ID="ButtonAddSubMenu" runat="server" Text="添加子节点" 
                                    OnClick="ButtonAddSubMenu_Click"  />
                                <br />
                                <br />
                                <asp:Button ID="ButtonDelete" runat="server" Text="删除该节点" onclick="ButtonDelete_Click"  />
                                <br />
                                <br />
                                    <asp:Label ID="lbSelectNodesText" runat="server" CssClass="Display"></asp:Label>
                                <br />
                                </div>
                            </td>
                            <td valign="top">
                                  <asp:HiddenField ID="hfAddressRoute" runat="server" />
                               <table border="0" cellpadding="0" cellspacing="0" class="division">
                                    <tr class="Display">
                                        <th>
                                            菜单项ID:</th>
                                        <td >
                                            <asp:TextBox ID="txtID" runat="server" ReadOnly="True"  />
                                            </td>
                                    </tr>
                                    <tr class="Display">
                                        <th>
                                            上级菜单项ID:</th>
                                        <td>
                                             <asp:TextBox ID="txtDepth" runat="server" ReadOnly="True" Text="0" />
                                            </td>
                                    </tr>
                                    <tr>
                                        <th>
                                             分类名称:</th>
                                        <td >
                                            <asp:TextBox ID="txtMenuName" runat="server" MaxLength="50" />
                                            </td>
                                    </tr>
                                    <tr >
                                        <th>
                                             商品类型:</th>
                                        <td>
                                            <asp:DropDownList ID="ddlProductTypeID" runat="server" CssClass="selectSingle" >
                                            <asp:ListItem Value="0">--请选择--</asp:ListItem>
                                            </asp:DropDownList>
                                            </td>
                                    </tr>
                                    <tr>
                                        <th>
                                            栏目地址:</th>
                                        <td>
                                             <asp:TextBox ID="txtMenuUrl" runat="server" MaxLength="50"  />
                                            </td>
                                    </tr>
                                    <tr>
                                        <th>
                                            模板类型:</th>
                                        <td>
                                             <asp:DropDownList ID="ddlTemplateUrl" runat="server" CssClass="selectSingle">
                                                <asp:ListItem Value="0">封面</asp:ListItem>
                                                <asp:ListItem Value="1" Selected="True">列表</asp:ListItem> 
                                                <asp:ListItem Value="2">单页</asp:ListItem>
                                            </asp:DropDownList>
                                            </td>
                                    </tr>
                                    <tr>
                                        <th>
                                            排&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;序:</th>
                                        <td>
                                            <asp:TextBox ID="txtWeight" runat="server" Text="0"  />
                                            </td>
                                    </tr>
                                    <tr>
                                        <th>
                                             是否显示:</th>
                                        <td>
                                             <asp:RadioButtonList ID="rblIsShow" runat="server" RepeatDirection="Horizontal" Width="100px" CssClass="RadioButtonListTable">
                                                <asp:ListItem Selected="True" Value="1">是</asp:ListItem>
                                                <asp:ListItem Value="0">否</asp:ListItem>
                                            </asp:RadioButtonList>
                                            </td>
                                    </tr>
                                                                        <tr>
                                        <th>
                                             允许评论:</th>
                                        <td>
                                             <asp:RadioButtonList ID="rbAllowReview" runat="server" RepeatDirection="Horizontal" Width="100px" CssClass="RadioButtonListTable">
                                                <asp:ListItem Value="1">是</asp:ListItem>
                                                <asp:ListItem Selected="True"  Value="0">否</asp:ListItem>
                                            </asp:RadioButtonList>
                                            </td>
                                    </tr>
                                    <tr>
                                        <th>
                                            </th>
                                        <td>
                                            <div class="EditBtnMenu">  
                                                <asp:Button ID="btUp" runat="server" onclick="btUp_Click" Text="提交" />
                                            </div>
                                            </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
    </form>
</body>
</html>
